#ifndef PHOTOWIDGET_H
#define PHOTOWIDGET_H

#include <QWidget>
#include <QLabel>   //标签
#include <QPushButton>  //按钮
#include <QLineEdit>    //编辑框   ctrl+/注释
#include <QCalendarWidget>
#include <QListWidget>
#include "model/imagemodel.h"
#include <QMouseEvent>
#include <QString>
#include <QMessageBox>
#include "model/usermodel.h"
#include <QCloseEvent>

class PhotoWidget : public QWidget
{
    Q_OBJECT
public:
    PhotoWidget();
    ~PhotoWidget();

    void init_window();
    void init_control();
    void init_connect();

private:
    QLabel *title, *inputDate;
    QPushButton *moreBtn, *calendarBtn, *backBtn;
    QCalendarWidget * calendar;
    QListWidget * listwidget;
    QListWidgetItem *listwidgetItem;
    QLabel *ImageLabel;

signals:
    //发送回到主界面的信号
    void backToMain();
public slots:
    void showImg(QListWidgetItem * image);
    void showCalendar();
    void on_calendarWidget_selectionChanged();


    // QWidget interface
protected:
    void closeEvent(QCloseEvent *event);
};

#endif // PHOTOWIDGET_H
